﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using FantastPlatform.Framework.IModel;

namespace FantastPlatform.Framework.IService
{
    public interface IOrganizationService : INodeService<IOrganization>
    {
        /// <summary>
        /// 得到当前组织下的员工
        /// </summary>
        /// <param name="organizationId"></param>
        /// <param name="keyword"></param>
        /// <param name="pageSize"></param>
        /// <param name="page"></param>
        /// <param name="totalCount"></param>
        /// <returns></returns>
        IList<IEmployee> LoadEmployeesByOrganizationId(int organizationId, int pageSize, int page, out int totalCount);
        /// <summary>
        /// 得到当前组织没有的岗位
        /// </summary>
        /// <param name="organizationId"></param>
        /// <returns></returns>
        IList<IPosition> LoadPositionNotExist(int organizationId, string keyword, int pageSize, int page, out int totalCount);
        /// <summary>
        /// 得到除当前子类外的组织
        /// </summary>
        /// <param name="organizationId"></param>
        /// <returns></returns>
        IList<IOrganization> LoadExceptChildrenOrganizations(int organizationId);
        /// <summary>
        /// 得到当前组织有的岗位
        /// </summary>
        /// <param name="organizationId"></param>
        /// <param name="pageSize"></param>
        /// <param name="page"></param>
        /// <param name="totalCount"></param>
        /// <returns></returns>
        IList<IPost> LoadPostsByOrganizationId(int organizationId, int pageSize, int page, out int totalCount);
        /// <summary>
        /// 根据名称获得部门
        /// </summary>
        /// <param name="name"></param>
        /// <returns></returns>
        IOrganization GetOrganizationByName(string name);
    }
}
